import { CommonListParams } from '@/api/model/common';
import { IObject } from '@/types/common';

export interface ResultList {
  list: ResultItem[];
  total: number;
}

export interface EquipmentInfo {
  id: string;
  name: string;
  type: number | string;
  model: string;
  number: string;
  address: string;
  uodateTime: string;
}

export interface videoInfo {
  id: string;
  type: number | string;
  url: string;
  transportProtocol: string;
  encodingFormat: string;
  decodingFormat: string;
  compressionFormat: string;
}

export interface outputInfo {
  deviceName: string;
  status: number | string;
  connect: number | string;
  deviceId: string;
}

export interface ResultItem {
  sn: string;
  dev_name: string;
  id: string;
  equipment: EquipmentInfo;
  video: videoInfo;
  output: Array<outputInfo>;
}

export interface ListParams extends CommonListParams {
  search?: Partial<PostData> & IObject;
}

export interface PostData {
  enable?: Boolean;
  sn?: string;
  dev_name?: string;
  deviceName?: string;
  urlId?: string;
  id?: string;
}

export interface IdItem {
  id: string;
}

export interface SmartData {
  id?: string;
  min_px: number;
  confidence: number;
  score: number;
  matching: number;
  proportion: number;
  interval: number;
}
